package cn.sofwin.day0120.homework.Bank;

import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        Account user = new Account();
        while (true){
            System.out.println("1.存款 2.取款 0.退出");
            System.out.print("请选择您需要办理的业务：");
            switch (sc.nextInt()){
                case 0:
                    System.out.println("谢谢使用！");
                    return;
                case 1:
                    System.out.print("请输入存款金额：");
                    user.inMoney(sc.nextInt());
                    break;
                case 2:
                    System.out.print("请输入取款金额：");
                    user.outMoney(sc.nextInt());
                    break;
                default:
                    System.out.println("输入是否有误");
            }
        }
    }
}
